﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using SAD.Common.Models;

namespace SAD.ShowClient.ShowItems
{
    /// <summary>
    /// ucNormalText.xaml 的交互逻辑
    /// </summary>
    public partial class ucNormalText : ShowItemBase
    {
        public ucNormalText(Info_Data infoData)
            : base(infoData)
        {
            InitializeComponent();

            SAD.ClientLogic.MainActivator.Current.debug_RecvCount++;

            //PhoneLable.Content = base.InfoData.SourceInfo;

            string xx = string.Format("{2}.{0}:{1}", base.InfoData.SourceInfo, base.InfoData.ShowData, base.InfoData.ID);

            if (xx.Length > 38)
                xx = xx.Substring(0, 38);

            TextLable.Content = xx; //string.Format("{0}.{1}", SAD.ClientLogic.MainActivator.Current.debug_RecvCount.ToString(), base.InfoData.ShowData);

            TextLable.Style = (Style)Resources["labelStyle1"];

            //if (SAD.ClientLogic.MainActivator.Current.debug_RecvCount % 2 == 0)
            //{
            //    TextLable.Style = (Style)Resources["labelStyle1"];
            //}
            //else
            //{
            //    //TextLable.Style = (Style)this.Resources["MessageLabelStyle_02"];
            //}
        }
    }
}
